package com.example.onedemotest.slice;

import com.example.onedemotest.ResourceTable;
import com.example.onedemotest.component.CustomComponent;
import ohos.aafwk.ability.AbilitySlice;
import ohos.aafwk.content.Intent;
import ohos.hiviewdfx.HiLog;
import ohos.hiviewdfx.HiLogLabel;

public class CustomComponentSlice extends AbilitySlice {


    private HiLogLabel hiLogLabel=new HiLogLabel(HiLog.LOG_APP,0x101, "CustomComponent");
    @Override
    protected void onStart(Intent intent) {
        super.onStart(intent);
        setUIContent(ResourceTable.Layout_custom_component_slice_layout);
        HiLog.info(hiLogLabel,"启动了","12455");
        HiLog.info(hiLogLabel,"onStart");
    }

    @Override
    protected void onActive() {
        super.onActive();
        HiLog.info(hiLogLabel,"onActive");
    }

    @Override
    protected void onForeground(Intent intent) {
        super.onForeground(intent);
        HiLog.info(hiLogLabel,"onForeground");
    }

    @Override
    protected void onInactive() {
        super.onInactive();
        HiLog.info(hiLogLabel,"onInactive");
    }

    @Override
    protected void onBackground() {
        super.onBackground();
        HiLog.info(hiLogLabel,"onBackground");
    }

    @Override
    protected void onStop() {
        super.onStop();
        HiLog.info(hiLogLabel,"onStop");
    }

    @Override
    public Object getLastStoredDataWhenConfigChanged() {
        return super.getLastStoredDataWhenConfigChanged();
    }

}
